namespace Daemon.Common.Helpers
{
	public static class FormatHelper
	{
		public static string FormatNumber(this int number)
		{
			if (number >= 10000)
			{
				int wCount = number / 10000;
				int more = number % 10000;
				string moreInfo = more == 0 ? string.Empty : "+";
				return $"{wCount}w" + $"{moreInfo}";
			}
			else if (number >= 1000)
			{
				int kCount = number / 1000;
				int more = number % 10000;
				string moreInfo = more == 0 ? string.Empty : "+";
				return $"{kCount}k" + $"{moreInfo}";
			}
			else
			{
				return number.ToString();
			}
		}
	}
}